package com.ketangpai.admin.dao;

import com.ketangpai.admin.entity.Directory;
import com.ketangpai.admin.entity.dto.SectionDTO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface SectionDao {
    @Select("SELECT * FROM section")
    List<SectionDTO> findAll();

    @Select("SELECT * FROM section WHERE section_id = #{sectionId}")
    Directory findByParentId(Integer sectionId);
}
